Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Travis ci use ctest #316

Merged
merged 1 commit into from
Jul 29, 2018
Merged

Conversation

psavery
Copy link
Collaborator

@psavery psavery commented Jul 16, 2018

This is a possibility to allow us to immediately use ctest without fixing the broken tests.

I wish ctest or gtest had an equivalent to pytest's 'xfail', but this is the closest I could get to
it. It prints out a message saying which tests are disabled at the end of each run. It can
function as a reminder to eventually fix them.

This builds off of PR #313.

Developer Certificate of Origin
Version 1.1

Copyright (C) 2004, 2006 The Linux Foundation and its contributors.
1 Letterman Drive
Suite D4700
San Francisco, CA, 94129

Everyone is permitted to copy and distribute verbatim copies of this
license document, but changing it is not allowed.

Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
have the right to submit it under the open source license
indicated in the file; or

(b) The contribution is based upon previous work that, to the best
of my knowledge, is covered under an appropriate open source
license and I have the right under that license to submit that
work with modifications, whether created in whole or in part
by me, under the same open source license (unless I am
permitted to submit under a different license), as indicated
in the file; or

(c) The contribution was provided directly to me by some other
person who certified (a), (b) or (c) and I have not modified
it.

(d) I understand and agree that this project and the contribution
are public and that a record of the contribution (including all
personal information I submit with it, including my sign-off) is
maintained indefinitely and may be redistributed consistent with
this project or the open source license(s) involved.

@psavery
Copy link
Collaborator Author

psavery commented Jul 16, 2018

This is just a possibility. If you would rather us not disable tests, that's fine - I can close this. Just let me know.

@psavery psavery force-pushed the travis-ci-use-ctest branch from 88341b2 to 8e0f030 Compare July 17, 2018 13:01
@psavery psavery force-pushed the travis-ci-use-ctest branch 2 times, most recently from 172864a to 3665303 Compare July 25, 2018 18:40
@psavery
Copy link
Collaborator Author

psavery commented Jul 25, 2018

Since PR #323 was accepted, I modified this PR so that the only change is that avogadrolibs now runs ctest instead of running the different tests directly.

If the tests all pass, this PR should be good to go.

@psavery
Copy link
Collaborator Author

psavery commented Jul 25, 2018

If ctest is ran directly, one of the tests fails with the following error:

33/36 Test #33: QtGui-FileBrowseWidget ...........***Exception: Other  0.23 sec
Running main() from gtest_main.cc
Note: Google Test filter = FileBrowseWidgetTest.*
[==========] Running 3 tests from 1 test case.
[----------] Global test environment set-up.
[----------] 3 tests from FileBrowseWidgetTest
[ RUN      ] FileBrowseWidgetTest.setFileName
QXcbConnection: Could not connect to display 

I will see if I can fix it with xvfb-run.

We are using xvfb-run because we need a display for the
QtGui-FileBrowseWidget test.

Signed-off-by: Patrick Avery <[email protected]>
@psavery psavery force-pushed the travis-ci-use-ctest branch from 3665303 to 807f3fe Compare July 25, 2018 19:06
@psavery
Copy link
Collaborator Author

psavery commented Jul 25, 2018

xvbf-run seemed to fix it.

This is ready for review.

@ghutchis
Copy link
Member

I realize this PR addresses Travis, but can we use ctest with Appveyor?

@ghutchis
Copy link
Member

I'm okay with the change, but I'd prefer to leave to @cryos to sign off on this.

@psavery
Copy link
Collaborator Author

psavery commented Jul 26, 2018

I added a PR for AppVeyor as well: PR #330.

Copy link
Member

@cryos cryos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is an improvement, if more output detail is preferred the -V flag will show the complete output of gtest.

@cryos cryos merged commit 31e034b into OpenChemistry:master Jul 29, 2018
@psavery psavery deleted the travis-ci-use-ctest branch August 30, 2018 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants